package com.example.demo.utils;

import lombok.Getter;
import lombok.Setter;

@Getter
@Setter
public class Result {
    int code;
    String msg;
    Object data;

    public static Result ok(){
        Result result = new Result();
        result.setCode(200);
        result.setMsg("操作成功");
        return result;
    }
    public static Result ok(Object data){
        Result result = ok();
        result.setData(data);
        return result;
    }
}
